<?php
class GuildBanAction extends SzAbstractAction {
    protected $paramTypes = array(
        SzAbstractAction::TYPE_INT,
        SzAbstractAction::TYPE_INT,
    );

    /**
     * @param $userId
     * @param $targetId
     * @return SzResponse
     * @throws SzException
     */
    public function execute($userId,$targetId) {
        if (!GameService::get()->verifySysUnlock($userId, GameConst::FUNC_GUILD)) {
            return $this->buildResponse(false);
        }

        return $this->buildResponse(
            GuildService::get()->ban($userId,$targetId)
        );
    }
}